<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
</head>
<body>
    <div>
        <button id="add">+</button>
        <span id="num">0</span>
        <button id="sub">-</button>
    </div>
</body>
<script>
    let num = 111;
    document.getElementById("num").innerHTML = num;
    document.getElementById("add").addEventListener("click",function(){
        num++;
        document.getElementById("num").innerHTML = num;
    });
    document.getElementById("sub").addEventListener("click",function(){
        num--;
        document.getElementById("num").innerHTML = num;
    });
</script>
</html>